package campus.aiit.ssl.dao;

import campus.aiit.ssl.domain.model.User;
import campus.aiit.ssl.manage.custom.dao.BaseDao;
import campus.aiit.ssl.manage.custom.dao.DaoResultCheck;

import java.util.List;
import java.util.Map;

/**
 * @author ihaokun
 * @date 2019/12/31 16:44
 */
public interface UserDao extends BaseDao<User> {
  @Override
  int insertSelective(User record);

  @Override
  int updateByPrimaryKeySelective(User record);

  List<User> selectAll(byte roleId);

  @DaoResultCheck
  int deleteByPrimaryKey(String id);

  User selectByPrimaryKey(String id);

  List<Map<String, Object>> getPropertyUser();

  Map getPropertyUserById(String id);

  int addPropertyUser(Map map);

  int updatePropertyUser(Map map);

  int delPropertyUser(String id);

  int updatePUserByAdmin(User user);

  User getUserById(String userId);

}